// ******************************************************************
// * Copyright(c)  Steven Lu
// * Description   : Entity_SEC_OBJECT
// * CreateDate    : 2014-06-05 18:30:40
// * Creater       : CodeSmith
// * LastChangeDate: 2014-06-05 18:30:40
// * LastChanger   : 2014-06-05 18:30:40
// * Version Info  : 1.0 For ESOL
// ******************************************************************

using System;
using System.Data;
using System.Collections.Generic;
using System.Text;
using System.Runtime.Serialization;
using Suzsoft.Smart.EntityCore;
using ESOL.Common.Schema;
using ESOL.Common;

namespace ESOL.Common.Entity
{
    [DataContract]
	[Serializable]
	public partial class SecObjectEntity : EntityBase
    {
        public SecObjectTable TableSchema
        {
            get
            {
                return SecObjectTable.Current;
            }
		}
		
		public SecObjectEntity()
        {

        }
		
		public SecObjectEntity(DataRow dr)
        {
			if(dr == null)
			{
				return;
			}
			this.ObjectId = Convert.ToString(CommonFunctions.ToObject(dr["OBJECT_ID"]));
			this.MenuId = Convert.ToString(CommonFunctions.ToObject(dr["MENU_ID"]));
			this.ObjectName = Convert.ToString(CommonFunctions.ToObject(dr["OBJECT_NAME"]));
			this.ObjectCode = Convert.ToString(CommonFunctions.ToObject(dr["OBJECT_CODE"]));
			this.ObjectRemark = Convert.ToString(CommonFunctions.ToObject(dr["OBJECT_REMARK"]));
        }
		
		public SecObjectEntity(DataRowView dr)
        {
			if(dr == null)
			{
				return;
			}
			this.ObjectId = Convert.ToString(CommonFunctions.ToObject(dr["OBJECT_ID"]));
			this.MenuId = Convert.ToString(CommonFunctions.ToObject(dr["MENU_ID"]));
			this.ObjectName = Convert.ToString(CommonFunctions.ToObject(dr["OBJECT_NAME"]));
			this.ObjectCode = Convert.ToString(CommonFunctions.ToObject(dr["OBJECT_CODE"]));
			this.ObjectRemark = Convert.ToString(CommonFunctions.ToObject(dr["OBJECT_REMARK"]));
        }

        public override TableInfo OringTableSchema
        {
            get
            {
                return SecObjectTable.Current;
            }
        }
		
		#region Perporty List
        [DataMember]
        public string ObjectId
        {
            get { return Convert.ToString(GetData(SecObjectTable.C_OBJECT_ID)); }
            set { SetData(SecObjectTable.C_OBJECT_ID, value); }
        }
		
        [DataMember]
        public string MenuId
        {
            get { return Convert.ToString(GetData(SecObjectTable.C_MENU_ID)); }
            set { SetData(SecObjectTable.C_MENU_ID, value); }
        }
		
        [DataMember]
        public string ObjectName
        {
            get { return Convert.ToString(GetData(SecObjectTable.C_OBJECT_NAME)); }
            set { SetData(SecObjectTable.C_OBJECT_NAME, value); }
        }
		
        [DataMember]
        public string ObjectCode
        {
            get { return Convert.ToString(GetData(SecObjectTable.C_OBJECT_CODE)); }
            set { SetData(SecObjectTable.C_OBJECT_CODE, value); }
        }
		
        [DataMember]
        public string ObjectRemark
        {
            get { return Convert.ToString(GetData(SecObjectTable.C_OBJECT_REMARK)); }
            set { SetData(SecObjectTable.C_OBJECT_REMARK, value); }
        }
		
		#endregion
	}
	
	
}	

